# Contributor: Maxim Karasev <begs@disroot.org>
# Maintainer: Maxim Karasev <begs@disroot.org>
pkgname=nvim-cmp-lsp
pkgver=0.0.0_git20220516
_commit=affe808a5c56b71630f17aa7c38e15c59fd648a8
pkgrel=0
pkgdesc="nvim-cmp source for neovim builtin LSP client"
url="https://github.com/hrsh7th/cmp-nvim-lsp"
arch="noarch !riscv64" # neovim
license="MIT"
subpackages="$pkgname-doc"
depends="nvim-cmp"
source="https://github.com/hrsh7th/cmp-nvim-lsp/archive/$_commit/nvim-cmp-$pkgver.tar.gz"
builddir="$srcdir/cmp-nvim-lsp-$_commit"
options="!check" # no tests

package() {
	install -d "$pkgdir"/usr/share/nvim/site
	cp -ra after doc lua "$pkgdir"/usr/share/nvim/site
	install -Dm644 README.md "$pkgdir"/usr/share/doc/$pkgname/README.md
}

doc() {
	default_doc
	amove usr/share/nvim/site/doc
}

sha512sums="
7a54d390579ec2410abcba138ffa833da49e5171decceda5e948281abe4f2938638c86380e9268678048c833af60d5d4f4f71c2968d058f050c742a051ffcbdd  nvim-cmp-0.0.0_git20220516.tar.gz
"
